package org.example.JVM;

/**
 * @Auther: Administrator
 * @Date: 2021/8/25 13:16
 * @Description:
 */
public class SuperClass {
    static {
        System.out.println("SuperClass init!");
    }

    public static int value = 123;
}

class SubClass extends SuperClass {
    static {
        System.out.println("SubClass init!");
    }
}

/**
 * 非主动使用类字段演示
 **/
class NotInitializationSuper {
    public static void main(String[] args) {
//        System.out.println(SubClass.value);
        SuperClass[] sca = new SuperClass[10];
    }
}